<?php


namespace app\admin\validate;

class ProjectsOrder extends Base
{
    protected $rule =   [
        'id'  => 'require',
        'ids'  => 'require',
        'order_status'  => 'require',
        'proj_id'  => 'require',
        'name'  => 'require',
        'status' => 'require',
        'drawing_img' => 'require',
    ];

    protected $message  =   [
        'id.require' => 'id必须',
        'ids.require' => 'ids必须',
        'order_status.require' => '订单状态必须',
        'proj_id.require' => '项目id必须',
        'name.require' => '订单名称必须',
        'status.require' => '状态必须',
        'drawing_img.require' => '图纸链接必须',
    ];


    protected $scene = [
        'insert'  =>  ['name','status','proj_id', 'order_status'],
        'update'  =>  ['id','status','order_status'],
        'detail'  =>  ['id'],
        'status'  =>  ['ids', 'status'],
        'del'  =>  ['ids'],
        'importExcel'  =>  ['proj_id'],
        'downloadDrawing'  =>  ['id','drawing_img'],
        'production'  =>  ['ids'],
        'clean'  =>  ['ids'],
    ];
}